home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
EnigmA Amiga Run 1996 June
/
EnigmA AMIGA RUN 08 (1996)(G.R. Edizioni)(IT)[!][issue 1996-06][EARSAN CD VII].iso
/
earcd
/
comm2
/
szflw011.lha
/
SizeFlow
/
SizeFlow.rexx
< prev
Wrap
OS/2 REXX Batch file
|
1996-05-08
|
887b
|
59 lines
/*
$VER: SizeFlow 0.11 (08.05.96)
(C) 1996 Robert Hofmann
*/
parse arg flow .
call Include_Lib('rexxsupport')
call pragma('W', 'NULL')
if ~open(in, flow, r) then
do
say '*** ERROR: Unable to open "'flow'"!'
exit 20
end
files = 0
total = 0
do while ~eof(in)
parse value statef(strip(readln(in), 'l', '-^#'))'0 0' with . size .
if size=0 then iterate
files = files+1
total = total+size
end
call close(in)
say flow': ' files 'Files =' total 'Bytes =' (total+512)%1024 'kB =' (((total+512)%1024)+512)%1024 'MB'
exit
Include_Lib: procedure
parse arg lib, prio
if right(upper(lib), 8)~='.LIBRARY' then lib = lib'.library'
if prio='' then prio = 0
if ~show('l', lib) then
if ~addlib(lib, prio, -30, 0) then
do
say '*** ERROR: Could not open' lib'!!! ***'
exit 10
end
return